#ifndef __IS_CORE_RAYTRACE_LIGHT__
#define __IS_CORE_RAYTRACE_LIGHT__

namespace IS
{
	class Light : public LinkListBase::Node<Light>
	{
	public:

		Light();

		virtual ~Light();

		/*! Notify this Light to begin ray tracing process
			Any ray-tracing resources are allocated here.
		*/
		virtual void beginRayTracing() = 0;

		/*! Notify this Light to end ray tracing process
			Any ray-tracing resources are released here.
		*/
		virtual void endRayTracing() = 0;

		/*! Get a ray for computing the visibility to this light from a point.
			This function must be called between the beginRayTracing() and endRayTracing()
		*/
		virtual void getVisibilityRay(const Vec3f& point, Ray& outRay) = 0;

		/*! Get the diffuse term contributed by this light to a point.
			This function must be called between the beginRayTracing() and endRayTracing()
		*/
		virtual void getDiffuse(const Vec3f& point, const Vec3f& normal, const Vec3f& outDiffuse) = 0;
	};
}

#endif	// __IS_CORE_RAYTRACE_LIGHT__